package com.sky.controller.admin;

import com.sky.dto.EmployeeDTO;
import com.sky.dto.SetmealDTO;
import com.sky.entity.Setmeal;
import com.sky.result.Result;
import com.sky.service.EmployeeService;
import com.sky.service.SetmealService;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 菜品管理
 */
@RestController
@RequestMapping(" /admin/setmeal")
@Slf4j
public class SetmealController {
    @Autowired
    private SetmealService setmealService;

    /**
     *
     * @param setmealDTO
     * @return
     */
    @PutMapping
    @ApiOperation("菜品跟新")
    public Result<String > update(@RequestBody SetmealDTO setmealDTO) {
        log.info("菜品跟新：{}", setmealDTO);
        setmealService.update(setmealDTO);




        return Result.success();
    }
}
